Skip to main content

EXIT_REJECTED

[[EXIT_REJECTED]]

Indicates that the completion of the quest has been rejected. It’s used in conditionals (IF ELSEIF ENDIF) in events like EXIT, ON_END, ON_END_ALLHEROES, ON_END_FIRSTHEROES, so that the hero can be allowed to finish the quest only if a specific condition is met.

  • Example: {[[(Y), ON_END]] [[IF: GET(bossKilled) = 1]] You killed the Boss, your quest is complete, you can leave! [[ELSEIF]] You cannot leave until you kill the boss! [[EXIT_REJECTED]] [[ENDIF]]}

In this example, a hero attempting to exit through the wooden door can leave and complete the quest only if they have killed the boss (which should be specified through the ON_DEATH event or the ON_DEATH parameter in the ADD_MONSTER event); otherwise, they will receive a message indicating they must kill the boss first.